@isTest

Private class WorkflowSummaryControllerTest {


    static testMethod void test_Workflow()

    {
       Workflow_definition__c wfd = new Workflow_definition__c();
       ApexPages.StandardController StdCtrl = new ApexPages.StandardController(wfd);
       WorkflowSummaryController controller = new WorkflowSummaryController(StdCtrl);
        
       wfd.Status__c = 'Active';
           wfd.Workflow_Name__c = 'WF';
           insert wfd;

       Workflow_definition__c wfd1 = new Workflow_definition__c();
       wfd1.Status__c = 'Build In Progress';
       wfd1.Workflow_Name__c = 'WF1';
       wfd1.Derived_from__c = wfd.id;
       insert wfd1;
       
       Fulfillment_Product_Group__c FP= new Fulfillment_Product_Group__c(Product_Group_Description__c='PROD',Product_Group_Code__c='PROD');  
       insert FP;     
               
       Workflow_Fulfillment_Group__c wfg = new Workflow_Fulfillment_Group__c();
       wfg.Advertiser_Region__c = 'test';
       wfg.Order_Types__c='Rest';
       wfg.Product_Group__c=FP.ID;
       wfg.Workflow__c = wfd.id;
       
       insert wfg;
       
       wfd1.Status__c = 'Active';
       Update wfd1;
              Workflow_Stage__c WFS = new Workflow_Stage__c();
            WFS.name = 'Advertiser Approval';
            WFS.Workflow_Code__c = wfd.id;
            insert WFS;
       Wokflow_Steps__c wfSteps = new Wokflow_Steps__c();
            wfSteps.name = 'Final Verification';
            wfSteps.Wokflow_Stage_Name__c = WFS.id;
            wfSteps.Target_Days__c = 12;
            insert wfSteps;
            //WS.Wokflow_Stage_Name__c = SD.id;
        Workflow_Activities__c WA = new Workflow_Activities__c();
            WA.name = 'Name';
            WA.Step_Name__c = wfSteps.id;
            WA.Status__c = 'Active';
            WA.Required__c= True;
            insert WA;
            
        controller.getWflowFunc();
        controller.getasgnGroups();
        controller.getWFDetails();
        controller.getWFDetails();      

            }
 }